package com.mall.service;


import com.mall.db.api.OmsOrderSettingApi;
import com.mall.pojo.OmsOrderSetting;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.stereotype.Service;

@Service
public class OmsOrderSettingService {

    @DubboReference
    private OmsOrderSettingApi omsOrderSettingApi;

    /**
     * 根据id获取指定订单设置
     * @param id
     * @return
     */
    public OmsOrderSetting findOrderSettingById(Integer id) {
        //调用方法进行查询指定订单
        OmsOrderSetting omsOrderSetting = omsOrderSettingApi.findOrderSettingById(id);

        return omsOrderSetting;

    }

    /**
     * 修改指定订单设置
     * @param orderSetting
     * @return
     */
    public Integer updateOrderSetting(OmsOrderSetting orderSetting) {
        //调用方法进行修改
        Integer updateNum = omsOrderSettingApi.updateOrderSetting(orderSetting);
        return updateNum;

    }
}
